<?php namespace Common\Model;
use Hdphp\Model\Model;

class ArcTag extends Model
{
	//指定表名
	protected $table = 'article_tag';
	
	//添加数据
	public function store($aid){
		//如果没有勾选,就给他空数组,不走foreach
		foreach (Q('post.tid',array()) as $tid){
			$data = array(
				'tag_tid'=>$tid,
				'article_aid'=>$aid,
			);
			$this->add($data);
		}
	}//store
	
	
}//class
?>